package org.wjy.post.vo;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

/**     
 * 类名称：User   
 * 类描述：用户信息实体
 * 创建人：anan   
 * 创建时间：2012-12-21 下午10:55:19   
 * 修改人：anan  
 * 修改时间：2012-12-21 下午10:55:19   
 * 修改备注：   
 * @version        
 * */
@Entity
@Table(name = "goods")
public class Goods {
	/**
	 * 用户id
	 */
	@Id
	@Column(name = "id")
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	private int id;
	
	/**
	 * 用户名
	 */
	@Column(name = "goodsnum", length = 255)
	private String goodsnum;
	
	/**
	 * 用户登录密码
	 */
	@Column(name = "goodsname", length = 255)
	private String goodsname;
	
	@Column(name = "goodssource", length = 255)
	private String goodssource;
	
	
	@Column(name = "purchaseprice")
	private double purchaseprice;
	
	@Column(name = "price")
	private double price;
	
	@Column(name = "stock",length=10)
	private int stock;
	

	public Goods() {
		// TODO Auto-generated constructor stub	
	}
	public Goods(int id) {
		// TODO Auto-generated constructor stub
		this.id=id;
	}
	
	public Goods(int id,String goodsnum,String goodsname){
		this.id=id;
		this.goodsnum=goodsnum;
		this.goodsname=goodsname;
	}
	public int getId() {
		return id;
	}




	public void setId(int id) {
		this.id = id;
	}




	public String getGoodsnum() {
		return goodsnum;
	}




	public void setGoodsnum(String goodsnum) {
		this.goodsnum = goodsnum;
	}




	public String getGoodsname() {
		return goodsname;
	}




	public void setGoodsname(String goodsname) {
		this.goodsname = goodsname;
	}




	public String getGoodssource() {
		return goodssource;
	}




	public void setGoodssource(String goodssource) {
		this.goodssource = goodssource;
	}




	public double getPurchaseprice() {
		return purchaseprice;
	}




	public void setPurchaseprice(double purchaseprice) {
		this.purchaseprice = purchaseprice;
	}




	public double getStock() {
		return stock;
	}




	public void setstock(int stock) {
		this.stock = stock;
	}
	
	public double getPrice() {
		return price;
	}




	public void setPrice(double price) {
		this.price = price;
	}




	@Override
	public String toString() {
		return "Goods [id=" + id + ", goodsnum=" + goodsnum + ", goodsname="
				+ goodsname + ", goodssource=" + goodssource
				+ ", purchaseprice=" + purchaseprice + ", price=" + price
				+ ", stock=" + stock + "]";
	}
	

}
